﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using HotelSoft.HotelManagement_BUS;
using HotelSoft.HotelManagement_DTO;

namespace HotelSoft.HotelManagement_GUI
{
    public partial class frmReport_BaoCaoDoanhThuNam : Form
    {
        BaoCaoDoanhThuTheoLoaiBUS busDT = new BaoCaoDoanhThuTheoLoaiBUS();
        THONGKE_NAMDTO dto = new THONGKE_NAMDTO();
        private int Nam;
        public int NAM
        {
            get { return Nam; }
            set { Nam = value; }
        }
        public frmReport_BaoCaoDoanhThuNam()
        {
            InitializeComponent();
        }

        private void Viewphong_Load(object sender, EventArgs e)
        {
            try
            {
                DataTable dt = new DataTable();
                docBaoCaoNam = new rptReport_BaoCaoNam();
                string s = Application.StartupPath + "\\rptReport_BaoCaoNam.rpt";
                docBaoCaoNam.Load(s);

                //dto.THANG = THANG;
                dto.NAM = NAM;
                dt = busDT.BaoCaoDoanhThuNam(dto);
                docBaoCaoNam.Database.Tables["command"].SetDataSource(dt);
                Viewphong.ReportSource = docBaoCaoNam;
            }
            catch { }
        }
    }
}
